package com.atguigu.utils;

/**
 * ClassName: MySqlUtil
 * Package: com.atguigu.utils
 * Description:
 *
 * @Author Lovxy
 * @Create 2023/5/15 10:49
 * @Version 1.0
 */
public class MySqlUtil {
    public static String getMysqlBaseSourceDDL() {
        return "CREATE TABLE base_source (\n" +
                "    id string,\n" +
                "    source_site string,\n" +
                "    PRIMARY KEY (id) NOT ENFORCED\n" +
                ") WITH (\n" +
                "   'connector' = 'jdbc',\n" +
                "   'url' = 'jdbc:mysql://hadoop102:3306/edu',\n" +
                "   'table-name' = 'base_source',\n" +
                "   'username' = 'root',\n" +
                "   'password' = '000000'\n" +
                ")";
    }
    public static String getMysqlTestPaper() {
        return "CREATE TABLE test_paper (\n" +
                "    id string,\n" +
                "    paper_title string,\n" +
                "    course_id string,\n" +
                "    PRIMARY KEY (id) NOT ENFORCED\n" +
                ") WITH (\n" +
                "   'connector' = 'jdbc',\n" +
                "   'url' = 'jdbc:mysql://hadoop102:3306/edu',\n" +
                "   'table-name' = 'test_paper',\n" +
                "   'username' = 'root',\n" +
                "   'password' = '000000'\n" +
                ")";
    }
}
